/*
 * @Author: 来自火星的码农 15122322+heyzhi@user.noreply.gitee.com
 * @Date: 2025-10-10 14:07:17
 * @LastEditors: 来自火星的码农 15122322+heyzhi@user.noreply.gitee.com
 * @LastEditTime: 2025-10-12 21:04:39
 * @FilePath: /GateServer/src/util/httpresponsebuilder.h
 * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
 */
#pragma once
#include "global.h"
#include <boost/beast/http/message.hpp>
#include <boost/beast/http/string_body.hpp>
#include <memory>
#include <sys/stat.h>
#include "util.h"
#include "jsoncpp/json/json.h"
namespace Yizhi {
    class HttpResponseBuilder{
        public:
        
        static void buildErrorResponse(http::response<http::dynamic_body>& response,Ecode code,const std::string &message);
        static void buildSuccessResponse(http::response<http::dynamic_body>& response,const Json::Value&data);
        static void buildJosnParseErrorResponse(http::response<http::dynamic_body>& response);
    };
}